package smdc.web.controller.system;

import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import smdc.common.core.controller.BaseController;
import smdc.system.util.JsonUtil;

/**
 * JsonController
 *
 * @author ruoyi
 * @date 2023-10-18
 */
@RestController
@RequestMapping("/system/json")
public class JsonController extends BaseController {


    /**
     * JSON美化工具
     */
    @PreAuthorize("@ss.hasPermi('system:json:format')")
    @GetMapping("/format/{params}")
    public String format(@PathVariable String params) {
        return JsonUtil.formatJson(params);
    }


}
